﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class product_OnlineSales_Item2 : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        Object Quantity = Session["Quantity"];
        if (Quantity != null)
        {

            if (!Util.IsBlank((String)Quantity))
            {
                this.Quantity.Text = "Quantity:";
                this.Quantity.Visible = true;
                this.Quantity.Text = (String)Quantity;
                this.Quantity.Visible = true;

            }
            else
            {
                this.Quantity.Visible = false;

            }

        }

        Object Item1 = Session["Product"];
        if (Item1 != null)
        {

            if (!Util.IsBlank((String)Item1))
            {
                this.Item1.Text = "Product:";
                this.Item1.Visible = true;
                this.Item1.Text = (String)Item1;
                this.Item1.Visible = true;

            }
            else
            {
                this.Item1.Visible = false;

            }
            Object DiscountedAmount3 = Session["Discount"];
            if (DiscountedAmount3 != null)
            {

                if (!Util.IsBlank((String)DiscountedAmount3))
                {
                    this.DiscountedAmount3.Text = "Discount:";
                    this.DiscountedAmount3.Visible = true;
                    this.DiscountedAmount3.Text = (String)DiscountedAmount3;
                    this.DiscountedAmount3.Visible = true;

                }
                else
                {
                    this.DiscountedAmount3.Visible = false;

                }


            }



            Object DiscountedPrice3 = Session["Price"];
            if (DiscountedPrice3 != null)
            {

                if (!Util.IsBlank((String)DiscountedPrice3))
                {
                    this.DiscountedPrice3.Text = "Price:";
                    this.DiscountedPrice3.Visible = true;
                    this.DiscountedPrice3.Text = (String)DiscountedPrice3;
                    this.DiscountedPrice3.Visible = true;

                }
                else
                {
                    this.DiscountedPrice3.Visible = false;

                }

            }
        }
    }
    protected void Button1_Click(object sender, EventArgs e)
    {
        Session["Quantity"] = Quantity.Text;
        Session["Product"] = Item1.Text;
        Session["Discount"] = DiscountedAmount3.Text;

        Server.Transfer("~/product/card/user/Machine.aspx");

    }
    protected void Button2_Click(object sender, EventArgs e)
    {
        Response.Redirect("OnlineSales.aspx");
    }
}